// 创建拦截器的类

function InterceptorManager () {
    this.handlers = []
}

InterceptorManager.prototype.use = function (fulfilled, rejected) {
    // 将两个函数包装成对象压入处理数组中
    this.handlers.push({ fulfilled, rejected })
}


module.exports = InterceptorManager